Importing tasks
The following section explains how to import a task using either the Qlik Replicate Console or the command line.
Before importing tasks, make sure that the tasks on the destination server are either running or stopped (i.e. not in the process of being started).
To import a task using the Qlik Replicate Console:
- Switch to Tasks view (make sure you're in Designer mode).
-
Click the Import Task toolbar button.
The Import Task dialog box opens.
-
Browse to the task JSON file you want to import and then click Import Task.
The task is imported.
To import a task using the command line:
-
From the Qlik Replicate computer where you want to import the task, open the Qlik Replicate command line console by doing the following:
From the Start menu, expand Qlik Replicate and then select Qlik Replicate Command Line.
A command-line console is displayed with the correct prompt for Qlik Replicate.
Information noteYou can also open the Windows command-line console and change the directory to the following:
<product_dir>\Attunity Replicate>\bin
For example to use the path to the directory where Qlik Replicate is installed by default, type: C:\Program Files\Attunity\Replicate\bin.
-
Run the following command:
repctl connect
-
To import the task, run the following command:
importrepository [-d data-directory] json_file=<Full path to the exported *.json file>
Example:
importrepository -d D:\MyData json_file=C:\Temp\many_tables.json
The exported *.json file will be located in the <data-directory>\imports folder on the original computer where the task was exported or in the folder specified by the folder_name parameter in the export command.
Example:
<product_dir>\data\imports\many_tables.json
Information noteIf the <product_dir>\data folder was installed in a non-default location during the installation - OR - if it was later moved to a non-default location, you need to tell Replicate where the folder is located.
This is done by including the -d data_folder parameter in the command.
Example:
repctl -d D:\MyData importrepository json_file=C:\mytask.json
If you are importing this task into a different environment, you should copy the file to a location on the second Qlik Replicate computer and then import the file from there.
In many cases, when you import the task into a different environment, you will need to make changes to the task. For example, you may need to change the connect strings for the endpoints in the task or change the user password. In that case, you will need to edit the *.json file.
See Editing an exported (json) file for more information.